import request from '@/utils/request'

// 查询顾客我的订单列表
export function getOrdersList(data) {
  return request({
    url: '/orders/list/by/user/id',
    method: 'POST',
	data
  })
}

// 普通会诊提交订单
export function ordersPut(data) {
  return request({
    url: '/orders/put',
    method: 'PUT',
	data
  })
}
// 特需会诊提交订单
export function ordersSave(data) {
  return request({
    url: '/orders/save/ningbo/tx',
    method: 'POST',
	data
  })
}

//  医生工作站:角标
export function getElBadge() {
  return request({
    url: '/orders/list/by/docker/id/count',
    method: 'GET',
  })
}

// 获取医生入口:任务池等tab点击进去的顾客列表
export function getOrdersListByDockerId(data) {
  return request({
    url: '/orders/list/by/docker/id',
    method: 'POST',
	data
  })
}

// 获取医生入口:任务池等tab点击进去的顾客列表退回
export function ordersSendBack(data) {
  return request({
    url: '/orders/sendBack',
    method: 'POST',
	data
  })
}

//患者申请退款
export function updateOrdersMainBody(data) {
  return request({
    url: '/orders/updateOrdersMainBody',
    method: 'POST',
	data
  })
}

//订单
export function getOrders(id) {
  return request({
    url: `/orders/${id}`,
    method: 'GET',
  })
}

//得到订单
export function ordersDoctorSave(ordersId) {
  return request({
    url: `/orders/doctorSave/${ordersId}`,
    method: 'GET',
  })
}
//区别此订单是否需要认领或者分配
export function claimOrAssign(data) {
  return request({
    url: `/orders/order/organizeAssignments`,
    method: 'POST',
	data
  })
}

//
export function updateOrderOwner(pOrdersDetailNumber) {
  return request({
    url: `/orders/updateOrderOwner/${pOrdersDetailNumber}`,
    method: 'GET',
  })
}

//
export function updateOrderOwnerNingbo(orderNumber) {
  return request({
    url: `/orders/updateOrderOwner/ningbo/tx/${orderNumber}`,
    method: 'GET',
  })
}

//申请医生会诊申请
export function ordersDoctorSavePut(data) {
  return request({
    url: `/orders/doctorSave`,
    method: 'PUT',
	data
  })
}

export function getAllOrderInfos(params) {
  return request({
    url: `/orders/all/order/info`,
    method: 'GET',
	params
  })
}



